package ${packageName};

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * ${feignClassName}
 *
 * @author OpenAI
 * @date ${.now?string("yyyy-MM-dd HH:mm:ss")}
 */
@FeignClient(name = "${feignName}")
public interface ${feignClassName} {

<#list methods as m>
/**
 * @return ${m.returnType}
 * @author OpenAI
 * @date ${.now?string("yyyy-MM-dd HH:mm:ss")}
 */
<#if m.httpMethod == "GET">
   @GetMapping(value = "${url}${m.url}")
   ${m.returnType} ${m.name}(<#list m.arguments as a><#if a_index!=0>, </#if><#list a.annotations as an>@${an} </#list>${a.argType} ${a.argName}</#list>);
</#if>
<#if m.httpMethod == "POST">
   @PostMapping(value = "${url}${m.url}")
   ${m.returnType} ${m.name}(<#list m.arguments as a><#if a_index!=0>, </#if><#list a.annotations as an>@${an} </#list>${a.argType} ${a.argName}</#list>);
</#if>
<#if m.httpMethod == "DELETE">
   @DeleteMapping(value = "${url}${m.url}")
   ${m.returnType} ${m.name}(<#list m.arguments as a><#if a_index!=0>, </#if><#list a.annotations as an>@${an} </#list>${a.argType} ${a.argName}</#list>);
</#if>
<#if m.httpMethod == "PUT">
   @PutMapping(value = "${url}${m.url}")
   ${m.returnType} ${m.name}(<#list m.arguments as a><#if a_index!=0>, </#if><#list a.annotations as an>@${an} </#list>${a.argType} ${a.argName}</#list>);
</#if>


</#list>
}
